﻿@{
    ViewBag.Title = "PrintReportImg";
}
@section scripts
{
    <script src="../Scripts/jquery-1.11.1.min.js" type="text/javascript"></script>
    <script src="../Scripts/miniui/miniui.js" type="text/javascript"></script>
    <script src="../Scripts/jquery.PrintArea.js" type="text/javascript"></script> 
    <script src="../Scripts/Base/print.js" type="text/javascript"></script> 
    <script src="../Scripts/shared/share.js" type="text/javascript"></script> 
        <style>
        .A4_v {
            margin:0 auto;
            margin-top:10px !important;
            margin-bottom:30px !important;
            border: 1px #D3D3D3 solid;
            background: white;
            box-shadow: 0 0 5px rgba(0, 0, 0, 0.1);
        }
        .QRimg {
            width:790px;
            height:1300px;
        }
        .hidden {
            display:none;
        }
        .Book {
            display:none;
        }

        .PrintArea {
            margin: 20px 5px;
            padding: 10px;
            width: 400px;
        }
        .buttonBar {
            height: 30px;
        }
        .buttonBar div {
            display: inline-block;
            float: left;
            margin-right: 10px;
            padding: 3px 12px;
            cursor: pointer;
        }
        .button {
            background: none repeat scroll 0 0 #999999;
            border: 1px solid blue;
            color: #EEEEEE;
            text-align: center;
        }

        div.settingName { display: inline-block; vertical-align: top; }
        div.settingVals { display: inline-block; padding-left: 10px; }

        span.test {
            color: red;
        }

        #Retain.PrintArea.area1 {
            border: 1px solid #999;
        }

        .PrintArea.area1 {
            border: solid 1px #ffb40f;
        }

        .PrintArea.area2 {
            border: solid 1px #20ff58;
        }

        .PrintArea.area3 {
            border: solid 1px #999;
        }
    </style>

}


    <div class="Book">
        
    </div>

    <input type="hidden" id="htmlstr" value="@ViewBag.htmlstr" />

    <script>
        
        $(function () {
            $(".Book").html($("#htmlstr").val());
            window.top.moveTo(0, 0);
            window.top.resizeTo(screen.availWidth, screen.availHeight);
            setTimeout(function () {
                $(".A4_v").printArea();                
                setTimeout(function () { onCancel(); }, 1500);
                //onCancel();
            }, 500);
        });
    </script>
